// 主要用来处理登录的逻辑
function loginReducer(state = { username: "" }, action) {
  switch (action.type) {
    case "login":
      return { username: "chen" };
    case "logout":
      return { username: "" };
    default:
      return state;
  }
}

export default loginReducer;
